package cc.vv.btpartyjob.partymanager.adapter

import android.widget.TextView
import cc.vv.baselibrary.adapter.SimpleCommonAdapter
import cc.vv.baselibrary.adapter.holder.ExtendViewHolder
import cc.vv.btpartyjob.jnimodule.server.OperationServer
import cc.vv.btpartyjob.partymanager.R
import cc.vv.btpartyjob.partymanager.moudel.bean.CommitInfoBean

/**
 * 单位承诺评价adapter
 * Created by Chen.qi on 2018/10/24.
 */
class UnitEvaluateAdapter(layoutResId: Int) : SimpleCommonAdapter<CommitInfoBean>(layoutResId) {

    override fun convert(helper: ExtendViewHolder, item: CommitInfoBean, position: Int) {
//        helper.getView<LinearLayout>(R.id.ll_ie_lookDetail).setOnClickListener({
//            LKToastUtil.showToastShort("查看详情")
//        })

//        helper.addOnClickListener(R.id.ll_ie_lookDetail)

        //名字
        helper.getView<TextView>(R.id.tv_ie_userName)?.text = "单位承诺"

        //承诺内容
        helper.getView<TextView>(R.id.tv_ie_dataContent)?.text = item.content

        //所属单位
//        helper.getView<TextView>(R.id.tv_ie_unitName)?.text = ""

        //时间
        helper.getView<TextView>(R.id.tv_ie_createTime)?.text = OperationServer.formatStr(item.completeTime)


    }
}